//
// Created by 66477 on 2022/9/24.
//

#ifndef DATA_STRUCTURE_NODE3_3_H
#define DATA_STRUCTURE_NODE3_3_H

#include <iostream>

using namespace std;

class Node3_3 {
private:
    Node3_3 *prior = nullptr;
    char data;
    int frep = 0;
    Node3_3 *next = nullptr;
public:
    Node3_3(char data) : data(data) {}

    Node3_3 *getPrior() const {
        return prior;
    }

    void addFrep() {
        frep++;
    }

    void setPrior(Node3_3 *prior) {
        Node3_3::prior = prior;
    }

    char getData() const {
        return data;
    }

    void setData(char data) {
        Node3_3::data = data;
    }

    int getFrep() const {
        return frep;
    }

    void setFrep(int frep) {
        Node3_3::frep = frep;
    }

    Node3_3 *getNext() const {
        return next;
    }

    void setNext(Node3_3 *next) {
        Node3_3::next = next;
    }
};

#endif //DATA_STRUCTURE_NODE3_3_H
